import Vue from 'vue'
import Vuex from 'vuex'

import createPersistedState from 'vuex-persistedstate'

Vue.use(Vuex)
// 使用 this.$store.state.MAP_IMG_URL
export default new Vuex.Store({
  state: {
    width: document.documentElement.clientWidth,
    height: document.documentElement.clientHeight,
    is: false,
    APP1_API: 'app1_v1',
    APP2_API: 'app2_v1'
  },
  mutations: {
    SET_APP1_API: (state, val) => {
      state.APP1_API = val
    },
    SET_APP2_API: (state, val) => {
      state.APP2_API = val
    }
  },
  actions: {
  },
  modules: {
  },
  plugins: [createPersistedState()]
})
